--string
str="abc"
print("str",str)

str2=string.upper(str)
print("str2",str2)
str3=string.lower(str2)
print("str3",str3)

--长度
str="hello"
print("hello",string.len(str))
print("len",#str)

print("你好",string.len("你好"))


--反转
str="hello"
print("反转",string.reverse(str))

--连接
print("a".."b")
str="hello"
print("拼接",str.."a".."hahah"..str)

--查找
str="hello"
print("find",string.find(str,"he"))
print("find",string.find(str,"hel"))
print("find",string.find(str,"eh"))

print("指定位置查询",string.find(str,"he",2))
print("指定位置查询",string.find(str,"he",1))

--正则匹配
str="hello12345"
print("正则",string.find(str,"%d"))

--ascii码转换
print("A",string.char(65))
